package com.company.cloud.coupon.modules.mgr.controller.req;

import java.math.BigDecimal;
import java.util.List;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;

import com.company.cloud.common.bean.BaseParam;
import com.company.cloud.common.constant.BaseConstant.YNEnum;
import com.company.cloud.coupon.constant.CouponConstant.CouponConfigTypeEnum;
import com.company.cloud.coupon.constant.CouponConstant.CouponEndDateTypeEnum;
import com.company.cloud.coupon.constant.CouponConstant.CouponGetType;
import com.company.cloud.coupon.constant.CouponConstant.CouponUsableObjTypeEnum;

import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

@Getter
@Setter
public class CouponConfigSaveParam extends BaseParam {

	
	@ApiModelProperty(value = "优惠券标题" ,required = true)
	@NotEmpty(message = "优惠券标题不能为空")
	private String title;

	@ApiModelProperty(value = "是否有使用门槛[YN]",required = true)
	@NotEmpty(message = "是否有使用门槛不能为空")
	private String isUseLimit = YNEnum.NO.getCode();
	
    @ApiModelProperty(value = "满多少时使用")
    private BigDecimal useFullFund;

	@ApiModelProperty(value = "优惠券类型[CouponConfigTypeEnum]" ,required = true)
	@NotEmpty(message = "优惠券类型不能为空")
	private String couponType=CouponConfigTypeEnum.Cash_Coupon.getCode();

	@ApiModelProperty(value = "优惠金额或折扣或优惠金额范围(小)" ,required = true)
	@NotNull(message = "优惠金额或折扣或优惠金额范围不能为空")
	private BigDecimal couponFund;
	
	@ApiModelProperty(value = "优惠金额范围(大)")
	private BigDecimal couponFundMax;
	
	@ApiModelProperty(value = "是否有最多优惠金额(YN)")
	private String isMaxDisFund;

	@ApiModelProperty(value = "最多优惠金额")
	private BigDecimal maxDisFund;


	@ApiModelProperty(value = "过期时间类型[CouponEndDateTypeEnum]"  ,required = true)
	@NotEmpty(message = "过期时间类型不能为空")
	private String useDateType=CouponEndDateTypeEnum.Appointed_EndDate.getCode();

	@ApiModelProperty(value = "开始时间固定 yyyy-mm-dd hh:mm:ss")
	private String useStartDate;
	
	@ApiModelProperty(value = "截止时间固定（yyyy-MM-dd HH:mm:ss）")
	private String useEndDate;

	@ApiModelProperty(value = "过期时间相对")
	private Integer useEndDay;

	@ApiModelProperty(value = "可用商品分类【CouponUsableObjTypeEnum】" ,required = true)
	@NotEmpty(message = "可用商品分类不能为空")
	private String usableObjType=CouponUsableObjTypeEnum.All_UsableObj.getCode();
	
	@ApiModelProperty(value = "可用商品")
	private List<String> usableObjNo;

	@ApiModelProperty(value = "优惠券总数量分类-是否限制[YNEnum]" ,required = true)
	@NotEmpty(message = "优惠券总数量分类不能为空")
	private String totalNumType=YNEnum.NO.getCode();

	@ApiModelProperty(value = "优惠券总数量")
	private Integer totalNum;

	@ApiModelProperty(value = "优惠券会员领取数量分类-是否限制[CouponGetType]" ,required = true)
	@NotEmpty(message = "优惠券会员领取数量分类不能为空")
	private String memberGetNumType=CouponGetType.CFG_None.getCode();

	@ApiModelProperty(value = "优惠券会员领取数量")
	private Integer memberGetNum;

	@ApiModelProperty(value = "优惠券使用会员分类-是否限制[YNEnum]",required = true)
	@NotEmpty(message = "优惠券使用会员分类不能为空")
	private String memberUseType=YNEnum.NO.getCode();

	@ApiModelProperty(value = "优惠券使用会员")
	private List<String> memberUse;

	@ApiModelProperty(value = "上下架状态(YNEnum)",required = true)
	@NotEmpty(message = "上下架状态不能为空")
	private String upperLowerState=YNEnum.NO.getCode();
	
	
	@ApiModelProperty(value = "是否过期提醒(YN)",required = true)
	@NotEmpty(message = "是否过期提醒不能为空")
	private String isRemind=YNEnum.NO.getCode();

	@ApiModelProperty(value = "过期提醒提前天数")
	private Integer remindDay;
	
	@ApiModelProperty(value = "分享设置(CouponShareEnum)")
	private List<String> shareSetting;

	@ApiModelProperty(value = "其他限制(CouponOtherEnum)")
	private  List<String> otherSetting;

}
